package com.sunrise.visual.frame.log
{
	import com.sunrise.visual.frame.error.ErrorManager;
	
	import mx.logging.ILogger;
	import mx.logging.Log;
	
	public class AlertErrorHandlerAction implements GlobalExceptionHandlerAction
	{
		private static const LOG:ILogger = Log.getLogger("UncaughtException");
		
		public function handle(error:Object):void
		{
			if (error is Error)
			{
				var errorObj:Error = error as Error;
				ErrorManager.addError(errorObj);
//				ErrorManager.addErrorMessage(errorObj.errorID+"--"
//					+errorObj.message +"--"
//					+errorObj.getStackTrace())
			}
		}
	}
}